﻿@{
    var set = NewLife.Cube.Setting.Current;
}
<div class="tab-pane fade in active" id="Login">
    <!-- Logo-->
    <div class="row text-center">
        <i class="glyphicon glyphicon-cloud login-logo center-block"></i>
    </div>
    <!-- 登录-->
    @using (Html.BeginForm("Login", "User", new { ReturnUrl = ViewBag.ReturnUrl }, FormMethod.Post, new { @class = "cube-login" }))
    {
        @Html.ValidationSummary()
        <span class="heading text-primary">用户登录</span>
        <div class="form-group">
            <input type="text" class="form-control" id="username" name="username" placeholder="用户名或电子邮件">
            <i class="glyphicon glyphicon-user"></i>
        </div>
        <div class="form-group">
            <input type="password" class="form-control" id="password" name="password" placeholder="密　码">
            <i class="glyphicon glyphicon-lock"></i>
            @*<a href="#Forgot" data-toggle="tab" class="glyphicon glyphicon-question-sign"></a>*@
        </div>
            <div class="form-group">
                <div class="main-checkbox">
                    <input type="checkbox" value="true" id="remember" name="remember" />
                    <label for="remember"></label>
                </div>
                <span class="text text-primary">记住我</span>
                <button type="submit" class="btn btn-default">登录</button>
            </div>

    }
    @if (set.AllowRegister || set.AllowForgot)
    {
        <div class="toolbar clearfix text-center">
            <div class="row" style="padding-top:30px;">
                @if (set.AllowForgot)
                {
                    <a href="#Forgot" data-toggle="tab">
                        <i class="glyphicon glyphicon-info-sign"></i>
                        忘记密码？
                    </a>

                }
                @if (set.AllowRegister)
                {

                    <a href="#Register" data-toggle="tab">                        
                        <i class="glyphicon glyphicon-menu-right"></i>
                        我要注册
                    </a>

                }
            </div>
        </div>
    }

    @if (!set.LoginTip.IsNullOrEmpty())
    {
        <h4 class="header blue lighter bigger">
            <i class="ace-icon fa fa-coffee green"></i>

        </h4>

        <div class="space-6"></div>

        <nav class="navbar navbar-fixed-top">
            <div class="alert alert-warning alert-dismissible text-center" role="alert" style="margin-bottom:0px;">
                <button type="button" class="close" data-dismiss="alert" aria-label="Close"><span aria-hidden="true">&times;</span></button>
                @Html.Raw(set.LoginTip)
            </div>
        </nav>
    }


</div>